Discover sonar static code analysis, include the articles, news, trends, analysis and practical advice about sonar static code analysis on alibabacloud.com
After the successful configuration of the Code Analysis page:You can see the complexity, syntax usage, repetition, and so on have been analyzed, specific to each method and each sentence of code.Four modes of use:Sonarqube + sonar-runnerSonarqube + mavensonarqube + eclipsesonarqube + IDE IntelliJMode of Use 1:Sonarqube + sona
First, install the Sonarqube service end, in other Computer browser landing, start to install other programming language detection plug-ins
The system has installed language plug-ins:
Download the languages that are commonly used in software projects:Android,CSS,Web,XML
Java-Related:Checkstyle,Findbugs,PMD
Java Static Analysis tool profiling objects
Application Technology
installation.Second, the project practice:1, the project root directory to create sonar-project.properties, configured as follows:The parameters are specific to your own project, language settings.2, cmd switch to the project root directory, input Sonar-scanner run can:3, after the end of the run, to Http://localhost:9000/view the test results, according to the test results to find problems in the
Use OCLint and Sonar for iOS code analysis and quality management, oclintios
OCLint is a powerful static code analysis tool that can be used to improve code quality and find potential b
Use Sonar for code Quality Management
This article describes how to build and use the code Quality Management Platform Sonar. Sonar is an open-source platform for managing the quality of source code. You will see the process from
Sonar Overview
Sonar is an open platform for code quality management. Through the plug-in mechanism, Sonar can integrate different test tools, code analysis tools, and continuous integration tools.
Unlike continuous integration
Demo address: http://nemo.sonarsource.org/http://www.sonarsource.org/downloads/
I. Brief Introduction
PrefaceSonar is an open-source platform for managing JavaSource codeQuality. From sonar 1.6, sonar has changed from a quality data reporting toolCodeQuality management platform.
Main features
1) code coverage: the unit test will show the lines of
Address: http://www.cnblogs.com/ericsun/archive/2011/09/19/2180827.html
I. Brief Introduction
PrefaceSonar is an open-source platform for managing the quality of Java source code. From sonar 1.6, sonar has changed from a quality data reporting tool to the current code quality management platform.
Main features
1)
sonar--Code Quality management platformFirst, basic understandingSonar (SonarQube) is an open source platform for managing the quality of source code. Sonar is not just a quality data reporting tool, but also a code quality management platform. through the plug-in mechanism,
and paste code is poor quality, sonar can show the source of repeated serious place5. insufficient comments or too many comments will make the code less readable, especially when people change inevitably, the readability of the program will be greatly reduced and too much comment will cause the developer to spend too much time on reading the comments, also contr
Obviously the program contains a lot of copy and paste code is poor quality, sonar can show the source of repeated serious place5. insufficient comments or too many comments will make the code less readable, especially when people change inevitably, the readability of the program will be greatly reduced and too much comment will cause the developer to spend too
1. Code Quality seven CrimesSonar is a code quality management system, its help document opening Ming Yi, put forward the code quality of the seven crimes, summed up in place, may wish a look:1. Bugs and Hidden Bugs (Bugs and potential Bugs)2. Violation of code specification (Coding standards Breach)3. Copy and paste (
the http://docs.codehaus.org/display/SONAR/Advanced+parameters
3,Run sonar-runner in the project directory.
4. Go to http: // localhost: 9000 to view the result, which is similar to the following:
The project's code volume, class distribution, and other indicators can be seen. This software integrates many open-source Java tools such as
. properties file with options including port and database information. If you want to modify it, you need to run the build-war.sh command before
4. Deploy sonar. War to the webapps directory of Tomcat
5. start Tomcat and access the relevant port to see the page
Use nginx for proxy:
For security considerations, nginx should be used as a proxy and basic authentication should be addedIi. Configuration
Security Configuration:
1. For security considerati
Now the system will usually have automated generated code, when using sonar for system code quality analysis, we want to be able to automatically generate code to exclude from the system analysis. This is very simple to implement,
Sonarqub E and J Enkin s Introduction
Sonarqub e is an open source code quality analysis platform that facilitates the management of code quality, and examines the vulnerabilities and potential logic issues of project code. At the same time, it provides a rich number of plug-ins to support the detection of multiple lan
How do different code branches do code analysis on Sonar? For example, one project has three branches of master, MySQL, and Xiangxiang, and 3 code-checking jobs are built on Jenkins, which is expected to be shown separately from the three-branch
When you use Sonar-scanner to scan your code, the error is as follows:
Error:error during Sonarqube Scanner executionJava.lang.IllegalStateException:Error when executing blame the for file ...... Java-----At Org.sonar.plugins.scm.svn.SvnBlameCommand.blame (svnblamecommand.java:102)At Org.sonar.plugins.scm.svn.SvnBlameCommand.blame (svnblamecommand.java:59)At Org.sonar.batch.scm.ScmSensor.execute (scmsens
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.